﻿/*****************************************************************************/
/* Stored Procedure ::                                                       */
/*****************************************************************************/
/* Copyright (C) 2007, Perot Systems Corporation. All right reserved.        */
/* Developer: Ed. Mueller (edward.mueller@ps.net)                            */
/* Created:  10/06/2007                                                      */
/*****************************************************************************/
CREATE PROCEDURE [Kernel].[ApplicantWith]( @ApplicantID BIGINT )
AS  
BEGIN

SELECT 
		Applicants.OID, 
		Applicants.Version as 'ApplicantVersion',
		Applicants.KinshipID,
		TypesOfKinship.Description as 'Kinship',
		Applicants.AddressID, 
		People.Version as 'PeopleVersion', 
		People.FirstName, 
		People.LastName, 
		People.MiddleInitial, 
		People.DOB, 
		People.Sex, 
		People.Phone1, 
		People.Phone2, 
		People.eMailAddress 
	From Applicants
	INNER JOIN People On Applicants.OID = People.OID
	INNER JOIN TypesOfKinship ON TypesOfKinship.OID = Applicants.KinshipID
	Where Applicants.OID = @ApplicantID

END


